package com.example.demo05.service;

import com.example.demo05.mapper.BookDaoMapper;
import com.example.demo05.pojo.Book;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class BookService {

    @Autowired
    private BookDaoMapper bookDaoMapper;

    //    public List<Book> getAllBooks();
    public List<Book> getAllBooks(){
        return bookDaoMapper.getAllBooks();
    }
//    public List<Book> getAllBooksAndPublisher();
    public List<Book> getAllBooksAndPublisher(){
        return bookDaoMapper.getAllBooksAndPublisher();
    }

}
